package _0813;

import java.util.*;

public class SortString {
    public static void main(String[] args) {
        List<String> list = new ArrayList<>();
        list.add("jack");
        list.add("tom");
        list.add("smith");
        list.add("rose");
        list.add("mary");
        list.add("Kobe");
        System.out.println("list原始数据:" + list);

        Collections.sort(list);
        System.out.println("list排序后:" + list);

        List<String> list1 = new ArrayList<>();
        list1.add("王老师");
        list1.add("传奇老师");
        list1.add("伟超老师");
        System.out.println("list1原始数据:" + list1);

        Collections.sort(list, new Comparator<String>() {
            @Override
            public int compare(String o1, String o2) {
                return 0;
            }
        });

    }
}
